
CREATE TABLE daycare.Allergies
  (
   AllergyId INT NOT NULL
                 IDENTITY(1,1)
                 PRIMARY KEY
 , AllergyName VARCHAR(100) NOT NULL
  )

CREATE TABLE daycare.ChildAllergies
  (
   ChildAllergyId INT NOT NULL
                      PRIMARY KEY
                      IDENTITY(1,1)
 , AllergyId INT NOT NULL
 , ChildID INT NOT NULL
 , AllergyNote VARCHAR(255)
  )
ALTER TABLE daycare.ChildAllergies ADD CONSTRAINT FK_ChildAllergies_Allergies FOREIGN KEY (AllergyId) REFERENCES daycare.Allergies(AllergyId)
ALTER TABLE daycare.ChildAllergies ADD CONSTRAINT FK_ChildAllergies_Children FOREIGN KEY (ChildId) REFERENCES daycare.Children(ChildId)
GO